import msg

def show():
	msg.show('-'*40, 'black', True);	
	msg.show('Help ', 'yellow', True);	
	
	# Update
	msg.show(' update|up:', 'green', True)
	msg.show('\tupdate local data', 'black', 1)
	
	# Lookup
	msg.show(' lookup|look|l:', 'green', True)
	msg.show('\tsearch for players, towns, alliances by keyword, or conquers by ocean', 'black', 1)
	msg.show('\tlookup <player|town|alliance> <name>', 'blue', True)
	msg.show('\tlookup conquers ocean', 'blue', True)
	
	# Map
	msg.show(' map|m:', 'green', True)
	msg.show('\tgenerate maps', 'black', 1)
	msg.show('\tmap', 'blue', True)
	msg.show('\tmap <ocean> <treshold> [player names]', 'blue', True)
	msg.show('\tmap 55 5000 bob harry', 'blue', True)
	
	# Define
	msg.show(' define|def|d:', 'green', True)
	msg.show('\tsee the structure of each dataset', 'black', True)
	msg.show('\tdefine <table>', 'blue', True)
	
	# Exit
	msg.show(' exit | ex:', 'green', True)
	msg.show('\tleave the program', 'black', True)
	
	msg.show('-'*40, 'black', True);	
	
def define(what):
	# Players
	if what == 'players' or what == 'player' or what == 'p':
		msg.show('Players: ', 'yellow')
		msg.show('id, name, alliance_id, points, rank, towns', 'blue', 1)
	
	# Towns
	elif what == 'towns' or what == 'town' or what == 't':
		msg.show('Towns: ', 'yellow')
		msg.show('id, player_id, name, island_x, island_y, number_on_island, points', 'blue', 1)
	
	# Alliances
	elif what == 'alliances' or what == 'alliance' or what == 'ally' or what == 'a':
		msg.show('Alliances: ', 'yellow')
		msg.show('id, name, points, villages, members, rank', 'blue', 1)
	
	# Islands
	elif what == 'islands' or what == 'island' or what == 'isle' or what == 'i':
		msg.show('Islands: ', 'yellow')
		msg.show('id, x, y, island_type, available_towns', 'blue', 1)
	
	# Conquers
	elif what == 'conquers' or what == 'conquer' or what == 'conq' or what == 'c':
		msg.show('Conquers: ', 'yellow')
		msg.show('town_id, time, new_player_id, old_player_id, new_ally_id, old_ally_id, town_points', 'blue', 1)
	
	# Nothing
	else:
		msg.show('Definition Not Found', 'red', 1)

if __name__ == '__main__':
	show()
